package lexical;

import node.Node;

public class Word implements Node {
    public final String word;
    public final Key key;
    public final Integer lineNum;

    public Word(String word, Key key, Integer lineNum) {
        this.word = word;
        this.key = key;
        this.lineNum = lineNum;
    }

    @Override
    public Node getFather() {
        return father;
    }

    @Override
    public String toString() {
        return key.toString() + " " + word + "\n";
    }

    @Override
    public String genMidCode() {
        return "";
    }
}
